package com.jiai.cloud.base.util;


public enum ErrorCode {
	/**
	 * 参数验证错误
	 */
    ILLEGAL_PARAMS(400, "请求参数有误!",null),
    /**
     * 服务器异常
     */
    SERVER_ERROR(500, "服务器内部异常!",null);
    

    ErrorCode(Integer code, String message,String description) {
        this.code = code;
        this.message = message;
    }

    private Integer code;

    private String message;
    private String description;
    
   

    public String getDescription() {
		return description;
	}
	public Integer getCode() {
		return code;
	}
    public String getMessage() {
        return message;
    }
    
    /**
     * 参数验证失败
     */
    public static final int  VALIDATE_ERROR_CODE=400;
    /**
     * 服务器内部异常
     */
    public static final int SERVER_ERROR_CODE=500;
    
    /**
     * 登录异常
     */
    public static final int LOGIN_ERROR=40001;
    
    /**
     * 未登录
     */
    public static final int NOT_LOGIN=40002;
    
    /**
     * 不存在该用户
     */
    public static final int NOT_USER=40003;
    /**
     * 用户已注册
     */
    public static final int USER_IS_CREATE=40004;
    
    /**
     * 没有权限
     */
    private static final int NOT_PERMISSION=40005;
    
 
    
}
